package com.ybt.communicate.core.parser;

import org.dom4j.Element;

import com.ybt.communicate.core.exception.ProtocolException;

public interface IProtocolParser<E> {

    public E parseCommon(E config, Element commonConfig)
            throws ProtocolException;

    public E parseRequest(E config, Element requestConfig)
            throws ProtocolException;

    public E parseResponse(E config, Element responseConfig)
            throws ProtocolException;

    public void convertCommon(E config, Element protocol)
            throws ProtocolException;

    public void convertRequest(E config, Element protocol)
            throws ProtocolException;

    public void convertResponse(E config, Element protocol)
            throws ProtocolException;
}
